<%@ page language="java" import="up7.*" pageEncoding="UTF-8"%>
<%@ page contentType="text/html;charset=UTF-8"%>
<%@	page import="com.google.gson.Gson" %>
<%@ page import="up7.model.*" %>
<%@ page import="up7.biz.*" %>
<%@ page import="up7.utils.*" %>
<%@	page import="org.apache.commons.lang.StringUtils" %>
<%@ page import="java.net.URLDecoder" %>
<%@ page import="java.net.URLEncoder" %>
<%@ page import="net.sf.json.JSONObject" %>
<%@ page import="up7.sql.SqlWhereMerge" %>
<%@ page import="up7.sql.SqlExec" %>
<%@ page import="net.sf.json.JSONArray" %>
<%@ page import="filemgr.PageFileMgr" %>
<%
    out.clear();

    WebBase web = new WebBase(pageContext);
    PageFileMgr mgr = new PageFileMgr();

    String id      = web.reqStr("id");
    boolean folder = web.reqBool("fdTask");
    String pathRel = web.reqStrDecode("pathRel");
    String nameNew = web.reqStrDecode("nameLoc");

    JSONObject v = null;
    if (folder)
    {
        v = mgr.rename_folder(id,pathRel,nameNew);
    }
    else
    {
        v = mgr.rename_file(id,pathRel,nameNew);
    }

    out.write(v.toString());
%>